from django.contrib import admin
from . import models
# Register your models here.

class AlgorithmProcessQueueInline(admin.StackedInline):
    model = models.AlgorithmProcessQueue
    extra = 0

class AlgorithmTaskAdmin(admin.ModelAdmin):
    inlines = [AlgorithmProcessQueueInline]
    list_display = ["workspace", "email", "id"]

class PDBIDTaskAdmin(admin.ModelAdmin):
    list_display = ["pdb_id"]

admin.site.register(models.AlgorithmUUIDUserRuntimeStatus)
admin.site.register(models.AlgorithmSystemRuntimeControl)
admin.site.register(models.AlgorithmSystemRuntimeStatus)
admin.site.register(models.AlgorithmUserRuntimeStatus)
admin.site.register(models.FileUpload)
admin.site.register(models.PDBIdLoad, PDBIDTaskAdmin)
admin.site.register(models.AlgorithmTask, AlgorithmTaskAdmin)